<!-- Message Error -->
<?php if ($this->session->flashdata('f_designers')): ?>
    <div class="msg msg-ok boxwidth">
        <p><strong><?php echo $this->session->flashdata('f_designers'); ?></strong></p>
    </div>
<?php endif; ?>


<!-- Box -->
<div class="box">
    <!-- Box Head -->
    <div class="box-head">
        <h2 class="left">+ <a href="<?php echo base_url();?>admin/designers/add" class="top_box_link">Add Designers</a></h2>
        <div class="right">
            <form action="<?php echo base_url();?>admin/designers/search" method="post">
                <label>search designer</label>
                <input type="text" class="field small-field" name="designer_name"/>
                <input type="submit" class="button" value="search" />
            </form>
        </div>
    </div>
    <!-- End Box Head -->	

    <!-- Table -->
    <div class="table">
        <table width="100%" border="0" cellspacing="0" cellpadding="0">
            <tr>
                <th>ID</th>
                <th>Nick Name</th>
                <th>Full Name</th>
                <th>City</th>
                <th>Nationality</th>
                <th>Gender</th>
                <th>Date Added/Modifed</th>
                <th width="110" class="ac">Control</th>
            </tr>
            <?php $i=0;?>
            <?php foreach($designers->result() as $d):?>
            <tr <?php echo (($i++%2)!=0)?'class="odd"':'';?>>
                <td class="column_id"><?php echo $d->id;?></td>
                <td><h3><a class="column_edit" title="edit this designer" href="<?php echo base_url();?>admin/designers/edit/<?php echo $d->id;?>"><?php echo $d->nick_name;?></a></h3></td>
                <td><?php echo $d->full_name;?></td>
                <td><?php echo $d->city;?></td>
                <td><?php echo $d->nationality_title;?></td>
                <td><?php echo ($d->gender=='M')?'Male':'Female';?></td>
                <td><?php echo $d->modified_date;?></td>
                <td><a href="<?php echo base_url();?>admin/designers/delete/<?php echo $d->id;?>" class="ico del column_delete">Delete</a><a href="<?php echo base_url();?>admin/designers/edit_photo/<?php echo $d->id;?>" class="ico edit">Photo</a></td>
            </tr>
            <?php endforeach;?>
        </table>
        <!-- Pagging -->
        <div class="pagging">
            <div class="left">
                Showing <?php echo $start+1;?>-<?php echo $start+$designers->num_rows();?> of <?php echo $count;?>
            </div>
            <div class="right">
                <?php if($page>1):?>
                <a href="<?php echo base_url();?>admin/designers/page/<?php echo $page-1;?>">Previous</a>
                <?php endif;?>
                <?php if(($start+$designers->num_rows()) < $count):?>
                <a href="<?php echo base_url();?>admin/designers/page/<?php echo $page+1;?>">Next</a>
                <?php endif;?>
            </div>
        </div>
        <!-- End Pagging -->

    </div>
    <!-- Table -->

</div>
<!-- End Box -->